local WorkStation = require'entities.workstation'

local ControlPanel = {}
ControlPanel.mt = { __index = ControlPanel }
setmetatable( ControlPanel, WorkStation.mt )


function  ControlPanel.initialize( x, y, ship)
	
	local CP = {}
	
	local res = {
		{ name = 'power', current = 100, max = 100, min = 0, rate = 1, base_rate = 1 },
		
	}
	
	local req = {
		[1] = function(self) 
			if self.res.power.current > self.res.power.min then 
				return true 
			end 
		end,
	
	}
	
	
	
	
	CP = WorkStation.new('control_panel', x, y, 100, 'control_panel', ship, res, req)	
	
	CP.x = x
	CP.y = y
	
	
	
	
	
	return CP
end

function ControlPanel:make_map()
	self.map = {}
	self.map[WIRE_TYPE] = self.ship.network_map[WIRE_TYPE]

end

function ControlPanel.new( x, y, ship )
	local o = ControlPanel.initialize( x, y, ship)
	
	
	return o
end





return ControlPanel